#include<stdio.h>
#include<unistd.h>
#include<stdlib.h>
#include<string.h>
#include<errno.h>

int main()
{
    //system("cp ./test.txt ./linktext.txt");
    int status = symlink("./test.txt", "./linktext.txt"); // ln -s  
    if (status == -1) {  
        perror("symlink failed");  
        return 1;  
    }  
    printf("Symlink created successfully.\n");  
    return 0; 
}